public class DVD {



        //DVD类
        private String name;
        private int state;
        private int date;
        private int count;


        //private表示私有，增加安全性


        //无参方法
        public DVD() {

        }

        //有参构造
        public DVD(String name, int state, int date, int count) {
            this.name = name;
            this.state = state;
            this.date = date;
            this.count = count;
        }

        public String getName() {
            return name;
        }

        public void setName(String name) {
            this.name = name;
        }

        public int getState() {
            return state;
        }

        public void setState(int state) {
            this.state = state;
        }

        public int getDate() {
            return date;
        }

        public void setDate(int date) {
            this.date = date;
        }

        public int getCount() {
            return count;
        }

        public void setCount(int count) {
            this.count = count;
        }


//toString方法

        @Override
        public String toString() {
            return "DVD [name='" + name +
                    ", state=" + state +
                    ", date=" + date +
                    ", count=" + count +
                    ']';
        }

}
